package com.qf.homework.service.impl;

import com.qf.homework.dao.CategoryDao;
import com.qf.homework.dao.impl.CategoryDaoImpl;
import com.qf.homework.entity.Category;
import com.qf.homework.service.CategoryService;
import com.qf.homework.utils.MyProxy;

import java.sql.SQLException;

public class CategoryServiceImpl implements CategoryService {
    private CategoryDao dao=null;

    public CategoryServiceImpl() {
        dao= new MyProxy(new CategoryDaoImpl()).getProxy();
    }

    @Override
    public int add(Category category) throws SQLException {
        return dao.add(category);
    }

}
